package com.martin.dms.dataservices;

import java.util.List;

import com.martin.dms.model.Category;

/**
 * Data services for the category entity.
 * 
 * @author mtsvetkov
 */
public interface CategoryDataService extends DMSDataService<Category> {

    /**
     * Updates the name of a category.
     * 
     * @param categoryId - id of the category.
     * @param name - the new name.
     */
    public void updateName(long categoryId, String name);

    /**
     * Adds an item to a category.
     * 
     * @param categoryId - id of the category.
     * @param itemId - id of the item.
     */
    public void addItem(long categoryId, long itemId);

    /**
     * Adds a list of items to a category.
     * 
     * @param categoryId - the id of the category.
     * @param itemIds - the list of item ids.
     */
    public void addItems(long categoryId, List<Long> itemIds);

    /**
     * Removes an item from a category.
     * 
     * @param categoryId - the id of the category.
     * @param itemId - the id of the item.
     */
    public void removeItem(long categoryId, long itemId);

    /**
     * Removes a list of items from a category.
     * 
     * @param categoryId - the id of the category.
     * @param itemIds - the list of item ids.
     */
    public void removeItems(long categoryId, List<Long> itemIds);
}
